3.4.51 \(\int (b \sec (e+f x))^m \tan ^5(e+f x) \, dx\) [351]

Optimal. Leaf size=67 \[ \frac {(b \sec (e+f x))^m}{f m}-\frac {2 (b \sec (e+f x))^{2+m}}{b^2 f (2+m)}+\frac {(b \sec (e+f x))^{4+m}}{b^4 f (4+m)} \]

[Out]

(b*sec(f*x+e))^m/f/m-2*(b*sec(f*x+e))^(2+m)/b^2/f/(2+m)+(b*sec(f*x+e))^(4+m)/b^4/f/(4+m)

________________________________________________________________________________________

Rubi [A]
time = 0.05, antiderivative size = 67, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {2686, 276} \begin {gather*} \frac {(b \sec (e+f x))^{m+4}}{b^4 f (m+4)}-\frac {2 (b \sec (e+f x))^{m+2}}{b^2 f (m+2)}+\frac {(b \sec (e+f x))^m}{f m} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(b*Sec[e + f*x])^m*Tan[e + f*x]^5,x]

[Out]

(b*Sec[e + f*x])^m/(f*m) - (2*(b*Sec[e + f*x])^(2 + m))/(b^2*f*(2 + m)) + (b*Sec[e + f*x])^(4 + m)/(b^4*f*(4 +
 m))

Rule 276

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*(a + b*x^n)^p,
 x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0]

Rule 2686

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rubi steps

\begin {align*} \int (b \sec (e+f x))^m \tan ^5(e+f x) \, dx &=\frac {b \text {Subst}\left (\int (b x)^{-1+m} \left (-1+x^2\right )^2 \, dx,x,\sec (e+f x)\right )}{f}\\ &=\frac {b \text {Subst}\left (\int \left ((b x)^{-1+m}-\frac {2 (b x)^{1+m}}{b^2}+\frac {(b x)^{3+m}}{b^4}\right ) \, dx,x,\sec (e+f x)\right )}{f}\\ &=\frac {(b \sec (e+f x))^m}{f m}-\frac {2 (b \sec (e+f x))^{2+m}}{b^2 f (2+m)}+\frac {(b \sec (e+f x))^{4+m}}{b^4 f (4+m)}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.46, size = 47, normalized size = 0.70 \begin {gather*} \frac {(b \sec (e+f x))^m \left (\frac {1}{m}-\frac {2 \sec ^2(e+f x)}{2+m}+\frac {\sec ^4(e+f x)}{4+m}\right )}{f} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(b*Sec[e + f*x])^m*Tan[e + f*x]^5,x]

[Out]

((b*Sec[e + f*x])^m*(m^(-1) - (2*Sec[e + f*x]^2)/(2 + m) + Sec[e + f*x]^4/(4 + m)))/f

________________________________________________________________________________________

Maple [C] Result contains higher order function than in optimal. Order 9 vs. order 3.
time = 0.57, size = 6797, normalized size = 101.45

method result size
risch \(\text {Expression too large to display}\) \(6797\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((b*sec(f*x+e))^m*tan(f*x+e)^5,x,method=_RETURNVERBOSE)

[Out]

result too large to display

________________________________________________________________________________________

Maxima [A]
time = 0.29, size = 82, normalized size = 1.22 \begin {gather*} \frac {\frac {b^{m} \cos \left (f x + e\right )^{-m}}{m} - \frac {2 \, b^{m} \cos \left (f x + e\right )^{-m}}{{\left (m + 2\right )} \cos \left (f x + e\right )^{2}} + \frac {b^{m} \cos \left (f x + e\right )^{-m}}{{\left (m + 4\right )} \cos \left (f x + e\right )^{4}}}{f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*sec(f*x+e))^m*tan(f*x+e)^5,x, algorithm="maxima")

[Out]

(b^m*cos(f*x + e)^(-m)/m - 2*b^m*cos(f*x + e)^(-m)/((m + 2)*cos(f*x + e)^2) + b^m*cos(f*x + e)^(-m)/((m + 4)*c
os(f*x + e)^4))/f

________________________________________________________________________________________

Fricas [A]
time = 0.40, size = 84, normalized size = 1.25 \begin {gather*} \frac {{\left ({\left (m^{2} + 6 \, m + 8\right )} \cos \left (f x + e\right )^{4} - 2 \, {\left (m^{2} + 4 \, m\right )} \cos \left (f x + e\right )^{2} + m^{2} + 2 \, m\right )} \left (\frac {b}{\cos \left (f x + e\right )}\right )^{m}}{{\left (f m^{3} + 6 \, f m^{2} + 8 \, f m\right )} \cos \left (f x + e\right )^{4}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*sec(f*x+e))^m*tan(f*x+e)^5,x, algorithm="fricas")

[Out]

((m^2 + 6*m + 8)*cos(f*x + e)^4 - 2*(m^2 + 4*m)*cos(f*x + e)^2 + m^2 + 2*m)*(b/cos(f*x + e))^m/((f*m^3 + 6*f*m
^2 + 8*f*m)*cos(f*x + e)^4)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \begin {cases} x \left (b \sec {\left (e \right )}\right )^{m} \tan ^{5}{\left (e \right )} & \text {for}\: f = 0 \\\frac {\int \frac {\tan ^{5}{\left (e + f x \right )}}{\sec ^{4}{\left (e + f x \right )}}\, dx}{b^{4}} & \text {for}\: m = -4 \\\frac {\int \frac {\tan ^{5}{\left (e + f x \right )}}{\sec ^{2}{\left (e + f x \right )}}\, dx}{b^{2}} & \text {for}\: m = -2 \\\frac {\log {\left (\tan ^{2}{\left (e + f x \right )} + 1 \right )}}{2 f} + \frac {\tan ^{4}{\left (e + f x \right )}}{4 f} - \frac {\tan ^{2}{\left (e + f x \right )}}{2 f} & \text {for}\: m = 0 \\\frac {m^{2} \left (b \sec {\left (e + f x \right )}\right )^{m} \tan ^{4}{\left (e + f x \right )}}{f m^{3} + 6 f m^{2} + 8 f m} + \frac {2 m \left (b \sec {\left (e + f x \right )}\right )^{m} \tan ^{4}{\left (e + f x \right )}}{f m^{3} + 6 f m^{2} + 8 f m} - \frac {4 m \left (b \sec {\left (e + f x \right )}\right )^{m} \tan ^{2}{\left (e + f x \right )}}{f m^{3} + 6 f m^{2} + 8 f m} + \frac {8 \left (b \sec {\left (e + f x \right )}\right )^{m}}{f m^{3} + 6 f m^{2} + 8 f m} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*sec(f*x+e))**m*tan(f*x+e)**5,x)

[Out]

Piecewise((x*(b*sec(e))**m*tan(e)**5, Eq(f, 0)), (Integral(tan(e + f*x)**5/sec(e + f*x)**4, x)/b**4, Eq(m, -4)
), (Integral(tan(e + f*x)**5/sec(e + f*x)**2, x)/b**2, Eq(m, -2)), (log(tan(e + f*x)**2 + 1)/(2*f) + tan(e + f
*x)**4/(4*f) - tan(e + f*x)**2/(2*f), Eq(m, 0)), (m**2*(b*sec(e + f*x))**m*tan(e + f*x)**4/(f*m**3 + 6*f*m**2
+ 8*f*m) + 2*m*(b*sec(e + f*x))**m*tan(e + f*x)**4/(f*m**3 + 6*f*m**2 + 8*f*m) - 4*m*(b*sec(e + f*x))**m*tan(e
 + f*x)**2/(f*m**3 + 6*f*m**2 + 8*f*m) + 8*(b*sec(e + f*x))**m/(f*m**3 + 6*f*m**2 + 8*f*m), True))

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*sec(f*x+e))^m*tan(f*x+e)^5,x, algorithm="giac")

[Out]

integrate((b*sec(f*x + e))^m*tan(f*x + e)^5, x)

________________________________________________________________________________________

Mupad [B]
time = 7.81, size = 199, normalized size = 2.97 \begin {gather*} \frac {\left (\cos \left (4\,e+4\,f\,x\right )-\sin \left (4\,e+4\,f\,x\right )\,1{}\mathrm {i}\right )\,{\left (\frac {b}{\cos \left (e+f\,x\right )}\right )}^m\,\left (\frac {2\,\cos \left (4\,e+4\,f\,x\right )\,\left (\cos \left (4\,e+4\,f\,x\right )+\sin \left (4\,e+4\,f\,x\right )\,1{}\mathrm {i}\right )}{f\,m}+\frac {\left (\cos \left (4\,e+4\,f\,x\right )+\sin \left (4\,e+4\,f\,x\right )\,1{}\mathrm {i}\right )\,\left (6\,m^2+4\,m+48\right )}{f\,m\,\left (m^2+6\,m+8\right )}-\frac {2\,\cos \left (2\,e+2\,f\,x\right )\,\left (\cos \left (4\,e+4\,f\,x\right )+\sin \left (4\,e+4\,f\,x\right )\,1{}\mathrm {i}\right )\,\left (4\,m^2+8\,m-32\right )}{f\,m\,\left (m^2+6\,m+8\right )}\right )}{16\,{\left (\frac {\cos \left (2\,e+2\,f\,x\right )}{2}+\frac {1}{2}\right )}^2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(e + f*x)^5*(b/cos(e + f*x))^m,x)

[Out]

((cos(4*e + 4*f*x) - sin(4*e + 4*f*x)*1i)*(b/cos(e + f*x))^m*((2*cos(4*e + 4*f*x)*(cos(4*e + 4*f*x) + sin(4*e
+ 4*f*x)*1i))/(f*m) + ((cos(4*e + 4*f*x) + sin(4*e + 4*f*x)*1i)*(4*m + 6*m^2 + 48))/(f*m*(6*m + m^2 + 8)) - (2
*cos(2*e + 2*f*x)*(cos(4*e + 4*f*x) + sin(4*e + 4*f*x)*1i)*(8*m + 4*m^2 - 32))/(f*m*(6*m + m^2 + 8))))/(16*(co
s(2*e + 2*f*x)/2 + 1/2)^2)

________________________________________________________________________________________